package com.qf.blog.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.qf.blog.dto.CommentDto;
import com.qf.blog.dto.IndexDiscussPostDto;
import com.qf.blog.dto.MyPage;
import com.qf.blog.entity.DiscussPost;
import com.qf.blog.vo.DiscussPostVo;
import com.qf.blog.vo.Topic;

import java.util.List;

/**
 * User: key
 * ClassName:DiscussPostService
 * Date: 2023/6/3
 * Time: 17:11
 * description:
 */
public interface DiscussPostService extends IService<DiscussPost> {
    public MyPage<IndexDiscussPostDto> indexDiscussPostData(IPage<IndexDiscussPostDto> page, Integer orderMode);
    public MyPage<IndexDiscussPostDto> indexDiscussPostData(IPage<IndexDiscussPostDto> page, Integer orderMode,String keyword);
    public MyPage<IndexDiscussPostDto> indexDiscussPostData(IPage<IndexDiscussPostDto> page, Integer orderMode,Integer entityId);

    List<CommentDto> getCommentListByPostId(Integer id);

    List<IndexDiscussPostDto> adminPostList();

    Integer updatePostType(Integer id, Integer type);

    Integer publishDiscuss(DiscussPostVo discussPostVo);
    MyPage discussPage(MyPage page);

    Topic detail(Integer id);

    Integer updatePostStatus(Integer id,Integer status);
}